from dataclasses import dataclass
from datetime import datetime
from typing import Optional


@dataclass
class BaseDTO:
    """数据传输对象基类"""
    id: Optional[int] = None
    created_at: Optional[datetime] = None
    updated_at: Optional[datetime] = None

@dataclass
class ListDTO:
    """列表查询结果"""
    items: list
    total: int
    page: int
    page_size: int